<template>
  <div class="type-wrap" v-for="attr in attrsList" :key="attr.attrId">
    <div class="fl key">{{ attr.attrName }}</div>
    <div class="fl value">
      <ul class="type-list">
        <li v-for="(attrValue, index) in attr.attrValueList" :key="index">
          <a @click="addAttrQuery(attr,attrValue)">{{ attrValue }}</a>
        </li>
      </ul>
    </div>
    <div class="fl ext"></div>
  </div>
</template>
<script setup lang="ts" name="AttrList">
import {inject} from "vue";

defineProps<{
  attrsList: any[]
}>()
const addAttrQuery = inject('addAttrQuery') as any
</script>
<style scoped lang="less">
@import "search-attr";
</style>
